<template>
    <div id="container"></div>
</template>

<script setup>
import { Line } from '@antv/g2plot'
import { onMounted } from 'vue';
const data = [
  { date: '01', value: 3 },
  { date: '02', value: 4 },
  { date: '03', value: 3 },
  { date: '04', value: 5 },
  { date: '05', value: 5 },
  { date: '06', value: 6 },
  { date: '07', value: 7 },
  { date: '08', value: 9 },
  { date: '09', value: 13 },
]

onMounted(() => {
  const line = new Line('container', {
    data,
    xField: 'date',
    yField: 'value',
  })
  line.render()
  line.update({theme: {background: '#FFFFFF'},})
})
</script>